import request from '../utils/request'
import httpRequest from '../utils/httpRequest'
import qs from 'qs'
export default {
    //获取menu菜单
    getMenuList(postData) {
        return request.send({
            method: 'post',
            path: '/who',
            postData: postData
        })
    },
    // 获取问题列表
    getProblemList(postData) {
        return request.send({
            method: 'post',
            path: '/print-api/feedback/getList',
            postData: postData,
        })
    },
    // 查询问题类型/关键词
    getQsDictionary(postData) {
        return request.send({
            method: 'post',
            path: '/print-api/dictionary/getQsDictionary',
            postData: postData
        })
        // return httpRequest.post('/print-api/dictionary/getQsDictionary', data)
    },
    //根据问题类型查询关键词
    getKeyWordsByTypeId(postData) {
        return request.send({
            method: 'post',
            path: `/print-api/dictionary/getKeyWordsByTypeId`,
            postData
        })
    },
    //文件上传
    uploadFile(data) {
        return httpRequest.post('/print-api/qsfile/uploadFile', data)
    },
    //添加问题
    addProblem(postData) {
        return request.send({
            method: 'post',
            path: '/print-api/feedback/save',
            postData: postData,
        })
    },
    //添加回复
    addReply(postData) {
        return request.send({
            method: 'post',
            path: '/print-api/feedbackReply/addReply',
            postData: postData,
        })
    },
    //获取反馈详情
    getInfo(postData) {
        return request.send({
            method: 'post',
            path: `/print-api/feedback/getInfo`,
            postData
        })
    },
    //添加热点问题
    addHotProblem(postData) {
        return request.send({
            method: 'post',
            path: '/print-api/feedback/saveHotspot',
            postData: postData,
        })
    },
    //获取热点问题列表
    getHotspotList(postData) {
        return request.send({
            method: 'post',
            path: '/print-api/feedback/getHotspotList',
            postData: postData,
        })
    },
    //获取全部问题热点列表
    getAllHotspotList(postData) {
        return request.send({
            method: 'post',
            path: '/print-api/feedback/getAllHotspotList',
            postData: postData,
        })
    },
}